﻿
using System;

namespace Sharp.Platform
{
    /// <summary>
    /// 实体
    /// </summary>
    [AttributeUsage(AttributeTargets.Class)]
    public class EntityAttribute : System.Attribute
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="EntityAttribute"/> class.
        /// </summary>
        /// <param name="type">The type.</param>
        public EntityAttribute(Type type)
        {
            this.Name = type.Name;
            this.Type = type;
        }

        /// <summary>
        /// 名称
        /// </summary>
        /// <value>名称</value>
        public string Name { get; set; }

        /// <summary>
        /// Gets or sets the type.
        /// </summary>
        /// <value>The type.</value>
        public Type Type { get; set; }
    }
}
